import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.Scanner;

public class Scanner_Test {
    public static void main1(String[] args) throws IOException {
        FileInputStream fileInputStream = new FileInputStream("D:/Test/新建文本文档.txt");
        Scanner scanner = new Scanner(fileInputStream,"UTF-8");
//        while(scanner.hasNextLine()) {
//            String line = scanner.nextLine();
//            System.out.println(line);
//        }
        while (true) {
            if(!scanner.hasNextLine()) {
                break;
            }
            String line = scanner.nextLine();
            System.out.println(line);
        }
        scanner.close();
        fileInputStream.close();
    }

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        System.out.println("输入：");
        scanner.nextLine();
        System.out.println("输入next：");
        scanner.next();
    }
;}
